<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@page import="com.lmpop.trade.ti_custword.*" %>
<%@page import="java.util.*" %>
<%@page import="com.lmpop.frame.util.PageTools" %>
<%
	request.setCharacterEncoding("UTF-8");
	Map ti_custword = new Hashtable();
	String s_title = "";
	if(request.getParameter("s_title")!=null && !request.getParameter("s_title").equals("")){
		s_title = request.getParameter("s_title");
		ti_custword.put("f_title",s_title);
	}
	String s_company = "";
	if(request.getParameter("s_company")!=null && !request.getParameter("s_company").equals("")){
		s_company = request.getParameter("s_company");
		ti_custword.put("f_cust_id",s_company);
	}
	Ti_custwordInfo ti_custwordInfo = new Ti_custwordInfo();
	String iStart = "0";
	int limit = 20;
	if(request.getParameter("iStart")!=null) iStart = request.getParameter("iStart");
	List list = ti_custwordInfo.getListByPage(ti_custword,Integer.parseInt(iStart),limit);
	int counter = ti_custwordInfo.getCountByObj(ti_custword);
	String pageString = new PageTools().getGoogleToolsBar(counter,"index.jsp?s_title="+s_title+"&s_company="+s_company+"&iStart=",Integer.parseInt(iStart),limit);
	
	String para ="s_title="+s_title+"&s_company="+s_company+"&iStart="+Integer.parseInt(iStart);
%>
<html>
  <head>
    
    <title>卖家反馈</title>
	<link href="/program/admin/index/css/style.css" rel="stylesheet" type="text/css">
	<script type="text/javascript" src="/js/commen.js"></script>
	<script type="text/javascript" src="custword.js" charset="UTF-8"></script>
</head>

<body>
	<table width="100%" cellpadding="0" cellspacing="0" border="0">
		<tr>
			<td width="90%">
				<h1>卖家反馈</h1>
			</td>
		</tr>
	</table>
	
	<form action="index.jsp" name="indexForm" method="post">
	<!--table width="100%" align="center" cellpadding="0" cellspacing="0" class="dl_so">
        <tr>
          <td width="9%" align="center"><img src="/program/admin/index/images/ban_01.gif" /></td>
          <td width="91%" align="left">
		  <h4>您可以按“行业”或“关键字”订阅</h4>
		  <span>1、填写关键字，您将及时了解与该产品相关的所有商机。</span><br/>
		  <span>2、为了更准确订阅，建议你选择产品所属的行业大类和行业子类。</span>
		  </td>
        </tr>
      </table-->
	<table width="100%" cellpadding="0" cellspacing="0" class="dl_su">
		<tr>
			<td align="left">
				标题:<input name="s_title" id="s_title" type="text" value="" />公司:<input name="s_company" id="s_company" type="text" value="" />
				<input name="searchInfo" type="button" value="查询" onclick="return search()" />	
			</td>
		</tr>
	</table>

	<table width="100%" cellpadding="0" cellspacing="0" border="0" class="tablehe">
		<tr><td align="center"><%=pageString%></td></tr>
	</table>
	
	<% 
		int listsize = 0;
		if(list!=null && list.size()>0){
			listsize = list.size();
	%>
	
	<table width="100%" cellpadding="0" cellspacing="0" border="0" class="dl_bg">
		<tr>
			<td width="90%">
				<input type="button" name="delInfo" onclick="delIndexInfo()" value="删除" class="buttab"/>
			</td>
			<td>
				总计:<%=counter %>条
			</td>
		</tr>
	</table>
	
	<table width="100%" cellpadding="1" cellspacing="1" class="listtab" border="0">
		<tr>
			<th width="5%" align="center"><input type="checkbox" name="checkall" id="checkall" onclick="delAllNews()"></th>
			
		  	<th>反馈标题</th>
		  	
		  	<th>反馈公司</th>
		  	
		  	<th>反馈时间</th>
		  	
		  	<th width="10%" align="middle">回复</th>
				
	  		<th width="10%" align="middle">删除</th>
		</tr>
		
		
		<% 		
		  		for(int i=0;i<list.size();i++){
		  			Hashtable map = (Hashtable)list.get(i);
		  			String word_id="",f_title="",f_content="",f_cust_id="",f_date="",cust_name = "";
		  			  	if(map.get("word_id")!=null) word_id = map.get("word_id").toString();
						  	if(map.get("f_title")!=null) f_title = map.get("f_title").toString();
						  	if(map.get("f_content")!=null) f_content = map.get("f_content").toString();
						  	if(map.get("f_cust_id")!=null) f_cust_id = map.get("f_cust_id").toString();
							if(map.get("cust_name")!=null) cust_name = map.get("cust_name").toString();
						  	if(map.get("f_date")!=null) f_date = map.get("f_date").toString();
								if(f_date.length()>19)f_date=f_date.substring(0,19);
						  	

		  %>
		
		<tr>
			<td width="5%" align="center"><input type="checkbox" name="checkone<%=i%>" id="checkone<%=i%>" value="<%=word_id%>"  /></td>

		  	<td><a href="updateInfo.jsp?word_id=<%=word_id%>&<%=para%>"><%=f_title%></a></td>
		  	
		  	<td><a href="javascript:document.getElementById('s_company').value='<%=cust_name%>';document.indexForm.submit();"><%=cust_name%></td>
		  	
		  	<td><%=f_date%></td>
		  	
		  	<td width="10%" align="middle"><a href="updateInfo.jsp?word_id=<%=word_id%>&<%=para%>"><img src="/program/admin/images/text.gif" title="回复" /></a></td>
				
	  		<td width="10%" align="middle"><a href="javascript:delOneNews('<%=word_id%>');"><img src="/program/admin/images/delete.gif" title="删除" /></a></td>
		</tr>
		
		  <%
		  		}
		  %>
		
	</table>
	
	<table width="100%" cellpadding="0" cellspacing="0" border="0" class="dl_bg">
		<tr>
			<td width="90%">
				<input type="button" name="delInfo" onclick="delIndexInfo()" value="删除" class="buttab"/>
			</td>
			<td>
				总计:<%=counter %>条
			</td>
		</tr>
	</table>
	<table width="100%" cellpadding="0" cellspacing="0" border="0" class="tablehe">
		<tr><td align="center"><%=pageString %></td></tr>
	</table>
	
	<%
		 }
	%>
	
	  <input type="hidden" name="listsize" id="listsize" value="<%=listsize %>" />
	  <input type="hidden" name="pkid" id="pkid" value="" />
	  <input type="hidden" name="bpm_id" id="bpm_id" value="4364" />
	</form>
	  
</body>

</html>
